package com.conception.designpattern.javabeanspattern;


// javabean allows insconsistency, mandates mutability

// inconvient  : the bbean may be in an inconsistent state partway through its construction
public class NutritionFacts {
	//parameters initialiser to the default value, if any.. 
	
	private int servingSize = -1; // required; no default value;
	private int serving  = -1;
	private int calories = 0;
	private int fat = 0;
	private int sodium = 0;
	
	
	public NutritionFacts(){}


	public void setServingSize(int servingSize) {
		this.servingSize = servingSize;
	}


	public void setServing(int serving) {
		this.serving = serving;
	}


	public void setCalories(int calories) {
		this.calories = calories;
	}


	public void setFat(int fat) {
		this.fat = fat;
	}


	public void setSodium(int sodium) {
		this.sodium = sodium;
	}
	

}
